﻿using System.Windows.Controls;
using Socium.Presentation.TreeViews;

namespace Socium.TestEditor {
	/// <summary>
	/// Interaction logic for MainWindow.xaml
	/// </summary>
	public partial class MainWindow {
		public MainWindow() {
			InitializeComponent();
		}

		private void TreeViewContextMenuOpening(object sender, ContextMenuEventArgs e) {
			var item = TreeViewHelper.GetNearestContainer(e.OriginalSource);
			if (item != null) {
				item.IsSelected = true;
			}
		}
	}
}
